<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>prencar: CubeApproach Class Reference</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>

</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  <td id="projectlogo"><img alt="Logo" src="prencar.png"/></td>
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">prencar
   &#160;<span id="projectnumber">1</span>
   </div>
   
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.8.0 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div>
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
  initNavTree('class_cube_approach.html','');
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Defines</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pub-attribs">Public Attributes</a> &#124;
<a href="#pri-methods">Private Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a> &#124;
<a href="#pri-static-attribs">Static Private Attributes</a>  </div>
  <div class="headertitle">
<div class="title">CubeApproach Class Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p><code>#include &lt;<a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>&gt;</code></p>
<div class="dynheader">
Collaboration diagram for CubeApproach:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach__coll__graph.png" border="0" usemap="#_cube_approach_coll__map" alt="Collaboration graph"/></div>
<map name="_cube_approach_coll__map" id="_cube_approach_coll__map">
<area shape="rect" id="node2" href="class_move.html" title="Move" alt="" coords="303,187,355,213"/><area shape="rect" id="node15" href="class_line_follow.html" title="LineFollow" alt="" coords="444,277,527,304"/><area shape="rect" id="node22" href="class_extended_move.html" title="Allows to define extended car control instuctions." alt="" coords="133,277,240,304"/><area shape="rect" id="node5" href="class_communication.html" title="Communication" alt="" coords="516,96,628,123"/><area shape="rect" id="node7" href="class_command.html" title="A Command object represents a command sent from the host software." alt="" coords="599,5,680,32"/><area shape="rect" id="node10" href="class_configuration.html" title="Configuration" alt="" coords="393,5,489,32"/><area shape="rect" id="node20" href="struct_cube_detection.html" title="CubeDetection" alt="" coords="629,277,736,304"/><area shape="rect" id="node27" href="struct_move_command.html" title="MoveCommand" alt="" coords="5,187,115,213"/></map>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>

<p><a href="class_cube_approach-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:aa02cb409570970adeb89e13c12678254"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#aa02cb409570970adeb89e13c12678254">CubeApproach</a> ()</td></tr>
<tr class="memitem:ac49270ba8b7c5bb6e60ffefc31175fc2"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#ac49270ba8b7c5bb6e60ffefc31175fc2">begin</a> ()</td></tr>
<tr class="memitem:ac36a5c38b1108d4cd77172062e1795be"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#ac36a5c38b1108d4cd77172062e1795be">doJob</a> (boolean followLine)</td></tr>
<tr class="memitem:ad221b0dcd79878c1ab47f1ab2a0076f2"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#ad221b0dcd79878c1ab47f1ab2a0076f2">startIt</a> ()</td></tr>
<tr><td colspan="2"><h2><a name="pub-attribs"></a>
Public Attributes</h2></td></tr>
<tr class="memitem:aeac3597ee8adcaf33fbf1a523de7c8e9"><td class="memItemLeft" align="right" valign="top"><a class="el" href="struct_cube_detection.html">CubeDetection</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#aeac3597ee8adcaf33fbf1a523de7c8e9">cubeDetections</a> [<a class="el" href="class_cube_approach.html#a0e1bfa9a8ab15c7762e4af35b4605003">_MAXRECORDABLECUBEDETECTIONS</a>]</td></tr>
<tr class="memitem:a6c44784cf83ba56f87895bb5c841e7df"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a6c44784cf83ba56f87895bb5c841e7df">amountOfCubeDetections</a></td></tr>
<tr class="memdesc:a6c44784cf83ba56f87895bb5c841e7df"><td class="mdescLeft">&#160;</td><td class="mdescRight">Counter that is increased each time the cube is detected by either the left or the right sensor.  <a href="#a6c44784cf83ba56f87895bb5c841e7df"></a><br/></td></tr>
<tr><td colspan="2"><h2><a name="pri-methods"></a>
Private Member Functions</h2></td></tr>
<tr class="memitem:a9a1321d9d53edf885345d9d4f3b2c765"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a9a1321d9d53edf885345d9d4f3b2c765">readBottomSensors</a> (int *resultArray)</td></tr>
<tr class="memitem:a1e002f33dc385e017d2b38120e8ce580"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a1e002f33dc385e017d2b38120e8ce580">readTopSensors</a> (int *resultArray)</td></tr>
<tr class="memitem:a2e637df1eece269b680fe9313798c241"><td class="memItemLeft" align="right" valign="top"><a class="el" href="struct_cube_detection.html">CubeDetection</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a2e637df1eece269b680fe9313798c241">tryToDetectCube</a> ()</td></tr>
<tr class="memitem:a7d68e4fab2b3f7590b21aef387855633"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a7d68e4fab2b3f7590b21aef387855633">turn</a> (int direction)</td></tr>
<tr><td colspan="2"><h2><a name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr class="memitem:ae99890596905ad65ee8a36a072a151cd"><td class="memItemLeft" align="right" valign="top">unsigned long&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#ae99890596905ad65ee8a36a072a151cd">_timeLastCubeApproachCheck</a></td></tr>
<tr class="memdesc:ae99890596905ad65ee8a36a072a151cd"><td class="mdescLeft">&#160;</td><td class="mdescRight">Holds the timestamp of the time when the last cube approach check was done.  <a href="#ae99890596905ad65ee8a36a072a151cd"></a><br/></td></tr>
<tr class="memitem:a1b9e5a99d916ad25e8cb522e9786afe7"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_communication.html">Communication</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a1b9e5a99d916ad25e8cb522e9786afe7">_com</a></td></tr>
<tr class="memdesc:a1b9e5a99d916ad25e8cb522e9786afe7"><td class="mdescLeft">&#160;</td><td class="mdescRight">The reference to the serial communication class.  <a href="#a1b9e5a99d916ad25e8cb522e9786afe7"></a><br/></td></tr>
<tr class="memitem:a91fd46dd8a9d594c3d6e516406bc4440"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_move.html">Move</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a91fd46dd8a9d594c3d6e516406bc4440">_move</a></td></tr>
<tr class="memdesc:a91fd46dd8a9d594c3d6e516406bc4440"><td class="mdescLeft">&#160;</td><td class="mdescRight">The reference to the move class to control the motors.  <a href="#a91fd46dd8a9d594c3d6e516406bc4440"></a><br/></td></tr>
<tr class="memitem:a69026de7ba3ae39f7298469faf69759e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_configuration.html">Configuration</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a69026de7ba3ae39f7298469faf69759e">_conf</a></td></tr>
<tr class="memdesc:a69026de7ba3ae39f7298469faf69759e"><td class="mdescLeft">&#160;</td><td class="mdescRight">The reference to the configuration class.  <a href="#a69026de7ba3ae39f7298469faf69759e"></a><br/></td></tr>
<tr class="memitem:a4e47fc77ece35197d5c1e2dda55334be"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_extended_move.html">ExtendedMove</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a4e47fc77ece35197d5c1e2dda55334be">_extMove</a></td></tr>
<tr class="memdesc:a4e47fc77ece35197d5c1e2dda55334be"><td class="mdescLeft">&#160;</td><td class="mdescRight">The reference to the extended move class.  <a href="#a4e47fc77ece35197d5c1e2dda55334be"></a><br/></td></tr>
<tr class="memitem:a2d3ac039bdca41b375557b0f0270e20d"><td class="memItemLeft" align="right" valign="top"><a class="el" href="class_line_follow.html">LineFollow</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a2d3ac039bdca41b375557b0f0270e20d">_lineFollow</a></td></tr>
<tr class="memdesc:a2d3ac039bdca41b375557b0f0270e20d"><td class="mdescLeft">&#160;</td><td class="mdescRight"><a class="el" href="class_line_follow.html">LineFollow</a> instance for the cube approach.  <a href="#a2d3ac039bdca41b375557b0f0270e20d"></a><br/></td></tr>
<tr class="memitem:a3831bd3f8a43dcdb1ca3c1ba185f43c4"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a3831bd3f8a43dcdb1ca3c1ba185f43c4">_stopCarExtMoveCommandId</a></td></tr>
<tr class="memdesc:a3831bd3f8a43dcdb1ca3c1ba185f43c4"><td class="mdescLeft">&#160;</td><td class="mdescRight">The id of the ext move command that is responsible for stopping the car after the cube has been detected the first time.  <a href="#a3831bd3f8a43dcdb1ca3c1ba185f43c4"></a><br/></td></tr>
<tr class="memitem:aae0fa8f88f1ea1c01e8528d7798a7db2"><td class="memItemLeft" align="right" valign="top">boolean&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#aae0fa8f88f1ea1c01e8528d7798a7db2">_stopCarNotYetDone</a></td></tr>
<tr class="memdesc:aae0fa8f88f1ea1c01e8528d7798a7db2"><td class="mdescLeft">&#160;</td><td class="mdescRight">True as long as "stop car" has not yet been performed.  <a href="#aae0fa8f88f1ea1c01e8528d7798a7db2"></a><br/></td></tr>
<tr><td colspan="2"><h2><a name="pri-static-attribs"></a>
Static Private Attributes</h2></td></tr>
<tr class="memitem:a0e1bfa9a8ab15c7762e4af35b4605003"><td class="memItemLeft" align="right" valign="top">static int const&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_cube_approach.html#a0e1bfa9a8ab15c7762e4af35b4605003">_MAXRECORDABLECUBEDETECTIONS</a> = 20</td></tr>
<tr class="memdesc:a0e1bfa9a8ab15c7762e4af35b4605003"><td class="mdescLeft">&#160;</td><td class="mdescRight">Defines, how many cube detections can be recorded.  <a href="#a0e1bfa9a8ab15c7762e4af35b4605003"></a><br/></td></tr>
</table>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock">
<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00019">19</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>
</div><hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="aa02cb409570970adeb89e13c12678254"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="class_cube_approach.html#aa02cb409570970adeb89e13c12678254">CubeApproach::CubeApproach</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Constructur for the class. </p>

<p>Definition at line <a class="el" href="_cube_approach_8cpp_source.html#l00009">9</a> of file <a class="el" href="_cube_approach_8cpp_source.html">CubeApproach.cpp</a>.</p>

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="ac49270ba8b7c5bb6e60ffefc31175fc2"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="class_cube_approach.html#ac49270ba8b7c5bb6e60ffefc31175fc2">CubeApproach::begin</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Prepares the <a class="el" href="class_cube_approach.html">CubeApproach</a> object to work together with other classes. The preparations done in here can not be done from within the constructor because of dependencies such as Serial communication. <b>This method needs to be called before this class can be fully used.</b> </p>

<p>Definition at line <a class="el" href="_cube_approach_8cpp_source.html#l00021">21</a> of file <a class="el" href="_cube_approach_8cpp_source.html">CubeApproach.cpp</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_ac49270ba8b7c5bb6e60ffefc31175fc2_cgraph.png" border="0" usemap="#class_cube_approach_ac49270ba8b7c5bb6e60ffefc31175fc2_cgraph" alt=""/></div>
<map name="class_cube_approach_ac49270ba8b7c5bb6e60ffefc31175fc2_cgraph" id="class_cube_approach_ac49270ba8b7c5bb6e60ffefc31175fc2_cgraph">
<area shape="rect" id="node3" href="class_communication.html#ad7b13fccf78bfce83efc9bb06c64facd" title="Communication::getInstance" alt="" coords="439,5,625,32"/><area shape="rect" id="node10" href="class_move.html#a5b53cfa443fe4fe0f1b96f9b3afc4850" title="Move::getInstance" alt="" coords="469,107,595,133"/><area shape="rect" id="node17" href="class_configuration.html#ae327d26e81014cf46b25802478fe9b8e" title="Configuration::getInstance" alt="" coords="446,157,618,184"/><area shape="rect" id="node21" href="class_extended_move.html#a8ba9c560726a121efa0c78f26780e46a" title="ExtendedMove::getInstance" alt="" coords="201,208,383,235"/><area shape="rect" id="node28" href="class_line_follow.html#afac0ad1ff185b7e5f9b47428cb2e5e48" title="LineFollow::begin" alt="" coords="231,107,353,133"/><area shape="rect" id="node5" href="class_communication.html#a88aa7a2d2ac5202e2b8eef787d1a8689" title="Communication::Communication" alt="" coords="680,5,891,32"/><area shape="rect" id="node8" href="class_configuration.html#a75b42e72d9a00415dfafa5d5dd8281b8" title="Configuration::getSerialSpeed" alt="" coords="939,5,1133,32"/><area shape="rect" id="node12" href="class_move.html#a4b1acc3a67d30c385ad9a6000526393a" title="Move::Move" alt="" coords="740,56,831,83"/><area shape="rect" id="node14" href="class_move.html#afcff6c5d4fd9e58382ee01d6270f4707" title="Move::begin" alt="" coords="740,107,831,133"/><area shape="rect" id="node19" href="class_configuration.html#a779947337bf652f0e773cb29f37f14ba" title="Configuration::Configuration" alt="" coords="695,157,875,184"/><area shape="rect" id="node23" href="class_extended_move.html#a4bf87fc8690c78ea76464cc8d006f528" title="ExtendedMove::ExtendedMove" alt="" coords="432,259,632,285"/><area shape="rect" id="node25" href="class_extended_move.html#aef13add1eb55a57abf64adbf4ae5f149" title="ExtendedMove::begin" alt="" coords="459,208,605,235"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_ac49270ba8b7c5bb6e60ffefc31175fc2_icgraph.png" border="0" usemap="#class_cube_approach_ac49270ba8b7c5bb6e60ffefc31175fc2_icgraph" alt=""/></div>
<map name="class_cube_approach_ac49270ba8b7c5bb6e60ffefc31175fc2_icgraph" id="class_cube_approach_ac49270ba8b7c5bb6e60ffefc31175fc2_icgraph">
<area shape="rect" id="node3" href="class_state_machine.html#a18b495baeae11732b76d252b2b8341c8" title="StateMachine::begin" alt="" coords="200,5,341,32"/><area shape="rect" id="node5" href="class_state_machine.html#a7f7482a9af6910035a62f9c116165f60" title="StateMachine::getInstance" alt="" coords="390,5,567,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="ac36a5c38b1108d4cd77172062e1795be"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="class_cube_approach.html#ac36a5c38b1108d4cd77172062e1795be">CubeApproach::doJob</a> </td>
          <td>(</td>
          <td class="paramtype">boolean&#160;</td>
          <td class="paramname"><em>followLine</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Does the job for which this class was written.<br/>
 This method has to be called in regular intervals.<br/>
 The sensor data of the distance sensors is captured and based on the result the car is controlled to either follow the line or drive to the cube.</p>
<p><b>Important: Call <a class="el" href="class_cube_approach.html#ad221b0dcd79878c1ab47f1ab2a0076f2">startIt()</a> first!</b></p>
<p>What's done in detail: </p>
<ol>
<li>
<dl class="todo"><dt><b><a class="el" href="todo.html#_todo000003">Todo:</a></b></dt><dd>Put some details in here. </dd></dl>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">followLine</td><td>If true, the car follows the line and tries to detect the cube. If false, the car drives straight forward and tries to detect. </td></tr>
  </table>
  </dd>
</dl>
</li>
</ol>

<p>Definition at line <a class="el" href="_cube_approach_8cpp_source.html#l00068">68</a> of file <a class="el" href="_cube_approach_8cpp_source.html">CubeApproach.cpp</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_ac36a5c38b1108d4cd77172062e1795be_cgraph.png" border="0" usemap="#class_cube_approach_ac36a5c38b1108d4cd77172062e1795be_cgraph" alt=""/></div>
<map name="class_cube_approach_ac36a5c38b1108d4cd77172062e1795be_cgraph" id="class_cube_approach_ac36a5c38b1108d4cd77172062e1795be_cgraph">
<area shape="rect" id="node3" href="class_line_follow.html#a93ff35747f2ae3bb26998f07243afc3c" title="LineFollow::doJob" alt="" coords="541,191,667,217"/><area shape="rect" id="node7" href="class_communication.html#a8679b3cb7ceef5527faa24454ce0f18a" title="Communication::send" alt="" coords="1395,292,1543,319"/><area shape="rect" id="node19" href="class_move.html#a9c5dc5c3a98abece0c2f40085c3601be" title="Move::controlMotors" alt="" coords="1140,571,1279,597"/><area shape="rect" id="node27" href="class_extended_move.html#a816f77b595c0ca03d44dd21b2d4de5ba" title="ExtendedMove::startCurrentQueue" alt="" coords="493,513,715,540"/><area shape="rect" id="node36" href="class_extended_move.html#a9bd37ba3d8f98170dd33c8726934735a" title="ExtendedMove::isExecutionInProcess" alt="" coords="203,668,445,695"/><area shape="rect" id="node39" href="class_cube_approach.html#a2e637df1eece269b680fe9313798c241" title="CubeApproach::tryToDetectCube" alt="" coords="798,393,1010,420"/><area shape="rect" id="node48" href="class_cube_approach.html#a7d68e4fab2b3f7590b21aef387855633" title="CubeApproach::turn" alt="" coords="255,513,393,540"/><area shape="rect" id="node5" href="class_line_follow.html#a1e3bb3e01044c86e7ad87c632bac6634" title="LineFollow::readFrontLineSensors" alt="" coords="1100,115,1319,141"/><area shape="rect" id="node10" href="class_move.html#a237261f2dd8fc115129f0ba998f13183" title="Move::performFastStop" alt="" coords="1131,165,1287,192"/><area shape="rect" id="node13" href="class_line_follow.html#af85fe355ee0699cabc3c817d10aa8b9d" title="LineFollow::readLineSensors" alt="" coords="810,216,998,243"/><area shape="rect" id="node16" href="class_move.html#a9d25d16f505526378fb4e43ee9e3b8c5" title="Move::setMotorSpeed" alt="" coords="830,267,978,293"/><area shape="rect" id="node22" href="class_move.html#af6b1197771f0540b0becc4117d8d272f" title="Move::setLeftMotorDirection" alt="" coords="1378,596,1561,623"/><area shape="rect" id="node24" href="class_move.html#a06e67dafd581bbd086da404a90c4eeec" title="Move::setRightMotorDirection" alt="" coords="1373,545,1565,572"/><area shape="rect" id="node30" href="class_extended_move.html#adfe6e7de87eab16e9a85ad5434819fee" title="ExtendedMove::executeCommand" alt="" coords="794,567,1014,593"/><area shape="rect" id="node34" href="class_extended_move.html#a80ce42b3578e4fa17b6b2e3a05a70054" title="ExtendedMove::getCurrentCommandInQueue" alt="" coords="763,516,1045,543"/><area shape="rect" id="node41" href="class_cube_approach.html#a9a1321d9d53edf885345d9d4f3b2c765" title="CubeApproach::readBottomSensors" alt="" coords="1094,419,1325,445"/><area shape="rect" id="node44" href="class_cube_approach.html#a1e002f33dc385e017d2b38120e8ce580" title="CubeApproach::readTopSensors" alt="" coords="1105,317,1314,344"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_ac36a5c38b1108d4cd77172062e1795be_icgraph.png" border="0" usemap="#class_cube_approach_ac36a5c38b1108d4cd77172062e1795be_icgraph" alt=""/></div>
<map name="class_cube_approach_ac36a5c38b1108d4cd77172062e1795be_icgraph" id="class_cube_approach_ac36a5c38b1108d4cd77172062e1795be_icgraph">
<area shape="rect" id="node3" href="class_state_machine.html#a32064aba8c9fa4afcb649d01aaf5fd78" title="StateMachine::doJob" alt="" coords="203,5,347,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a9a1321d9d53edf885345d9d4f3b2c765"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="class_cube_approach.html#a9a1321d9d53edf885345d9d4f3b2c765">CubeApproach::readBottomSensors</a> </td>
          <td>(</td>
          <td class="paramtype">int *&#160;</td>
          <td class="paramname"><em>resultArray</em></td><td>)</td>
          <td><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Reads the two bottom distance sensors and returns their values. </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">Pointer</td><td>to an int array where the two result values will be filled in. [0] bottom left sensor; [1] bottom right sensor </td></tr>
  </table>
  </dd>
</dl>
<dl class="todo"><dt><b><a class="el" href="todo.html#_todo000004">Todo:</a></b></dt><dd>Maybe a delay is needed between the readings. </dd></dl>

<p>Definition at line <a class="el" href="_cube_approach_8cpp_source.html#l00127">127</a> of file <a class="el" href="_cube_approach_8cpp_source.html">CubeApproach.cpp</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_a9a1321d9d53edf885345d9d4f3b2c765_cgraph.png" border="0" usemap="#class_cube_approach_a9a1321d9d53edf885345d9d4f3b2c765_cgraph" alt=""/></div>
<map name="class_cube_approach_a9a1321d9d53edf885345d9d4f3b2c765_cgraph" id="class_cube_approach_a9a1321d9d53edf885345d9d4f3b2c765_cgraph">
<area shape="rect" id="node3" href="class_communication.html#a8679b3cb7ceef5527faa24454ce0f18a" title="Communication::send" alt="" coords="286,5,434,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_a9a1321d9d53edf885345d9d4f3b2c765_icgraph.png" border="0" usemap="#class_cube_approach_a9a1321d9d53edf885345d9d4f3b2c765_icgraph" alt=""/></div>
<map name="class_cube_approach_a9a1321d9d53edf885345d9d4f3b2c765_icgraph" id="class_cube_approach_a9a1321d9d53edf885345d9d4f3b2c765_icgraph">
<area shape="rect" id="node3" href="class_cube_approach.html#a2e637df1eece269b680fe9313798c241" title="CubeApproach::tryToDetectCube" alt="" coords="286,5,498,32"/><area shape="rect" id="node5" href="class_cube_approach.html#ac36a5c38b1108d4cd77172062e1795be" title="CubeApproach::doJob" alt="" coords="547,5,696,32"/><area shape="rect" id="node7" href="class_state_machine.html#a32064aba8c9fa4afcb649d01aaf5fd78" title="StateMachine::doJob" alt="" coords="744,5,888,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a1e002f33dc385e017d2b38120e8ce580"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="class_cube_approach.html#a1e002f33dc385e017d2b38120e8ce580">CubeApproach::readTopSensors</a> </td>
          <td>(</td>
          <td class="paramtype">int *&#160;</td>
          <td class="paramname"><em>resultArray</em></td><td>)</td>
          <td><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Reads the two top distance sensors and returns their values. </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">Pointer</td><td>to an int array where the two result values will be filled in. [0] top left sensor; [1] top right sensor </td></tr>
  </table>
  </dd>
</dl>
<dl class="todo"><dt><b><a class="el" href="todo.html#_todo000005">Todo:</a></b></dt><dd>Maybe a delay is needed between the readings. </dd></dl>

<p>Definition at line <a class="el" href="_cube_approach_8cpp_source.html#l00140">140</a> of file <a class="el" href="_cube_approach_8cpp_source.html">CubeApproach.cpp</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_a1e002f33dc385e017d2b38120e8ce580_cgraph.png" border="0" usemap="#class_cube_approach_a1e002f33dc385e017d2b38120e8ce580_cgraph" alt=""/></div>
<map name="class_cube_approach_a1e002f33dc385e017d2b38120e8ce580_cgraph" id="class_cube_approach_a1e002f33dc385e017d2b38120e8ce580_cgraph">
<area shape="rect" id="node3" href="class_communication.html#a8679b3cb7ceef5527faa24454ce0f18a" title="Communication::send" alt="" coords="265,5,413,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_a1e002f33dc385e017d2b38120e8ce580_icgraph.png" border="0" usemap="#class_cube_approach_a1e002f33dc385e017d2b38120e8ce580_icgraph" alt=""/></div>
<map name="class_cube_approach_a1e002f33dc385e017d2b38120e8ce580_icgraph" id="class_cube_approach_a1e002f33dc385e017d2b38120e8ce580_icgraph">
<area shape="rect" id="node3" href="class_cube_approach.html#a2e637df1eece269b680fe9313798c241" title="CubeApproach::tryToDetectCube" alt="" coords="265,5,477,32"/><area shape="rect" id="node5" href="class_cube_approach.html#ac36a5c38b1108d4cd77172062e1795be" title="CubeApproach::doJob" alt="" coords="525,5,675,32"/><area shape="rect" id="node7" href="class_state_machine.html#a32064aba8c9fa4afcb649d01aaf5fd78" title="StateMachine::doJob" alt="" coords="723,5,867,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="ad221b0dcd79878c1ab47f1ab2a0076f2"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="class_cube_approach.html#ad221b0dcd79878c1ab47f1ab2a0076f2">CubeApproach::startIt</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Starts the cube detection process. </p>

<p>Definition at line <a class="el" href="_cube_approach_8cpp_source.html#l00044">44</a> of file <a class="el" href="_cube_approach_8cpp_source.html">CubeApproach.cpp</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_ad221b0dcd79878c1ab47f1ab2a0076f2_cgraph.png" border="0" usemap="#class_cube_approach_ad221b0dcd79878c1ab47f1ab2a0076f2_cgraph" alt=""/></div>
<map name="class_cube_approach_ad221b0dcd79878c1ab47f1ab2a0076f2_cgraph" id="class_cube_approach_ad221b0dcd79878c1ab47f1ab2a0076f2_cgraph">
<area shape="rect" id="node3" href="class_line_follow.html#a98fad8edd42d3096bb61f9e68293490c" title="LineFollow::startIt" alt="" coords="203,5,327,32"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_ad221b0dcd79878c1ab47f1ab2a0076f2_icgraph.png" border="0" usemap="#class_cube_approach_ad221b0dcd79878c1ab47f1ab2a0076f2_icgraph" alt=""/></div>
<map name="class_cube_approach_ad221b0dcd79878c1ab47f1ab2a0076f2_icgraph" id="class_cube_approach_ad221b0dcd79878c1ab47f1ab2a0076f2_icgraph">
<area shape="rect" id="node3" href="class_state_machine.html#a32064aba8c9fa4afcb649d01aaf5fd78" title="StateMachine::doJob" alt="" coords="203,5,347,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a2e637df1eece269b680fe9313798c241"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="struct_cube_detection.html">CubeDetection</a> * <a class="el" href="class_cube_approach.html#a2e637df1eece269b680fe9313798c241">CubeApproach::tryToDetectCube</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Tries to detect the cube and returns 0 if no detection was possible or a reference to the latest object inside cubeDetections if the cube could be detected. </p>
<dl class="section return"><dt>Returns:</dt><dd>0 if the cube was not detected or a reference to the lastest object inside cubeDetections if the cube could be detected. </dd></dl>

<p>Definition at line <a class="el" href="_cube_approach_8cpp_source.html#l00153">153</a> of file <a class="el" href="_cube_approach_8cpp_source.html">CubeApproach.cpp</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_a2e637df1eece269b680fe9313798c241_cgraph.png" border="0" usemap="#class_cube_approach_a2e637df1eece269b680fe9313798c241_cgraph" alt=""/></div>
<map name="class_cube_approach_a2e637df1eece269b680fe9313798c241_cgraph" id="class_cube_approach_a2e637df1eece269b680fe9313798c241_cgraph">
<area shape="rect" id="node3" href="class_cube_approach.html#a9a1321d9d53edf885345d9d4f3b2c765" title="CubeApproach::readBottomSensors" alt="" coords="267,5,498,32"/><area shape="rect" id="node5" href="class_communication.html#a8679b3cb7ceef5527faa24454ce0f18a" title="Communication::send" alt="" coords="547,56,695,83"/><area shape="rect" id="node7" href="class_cube_approach.html#a1e002f33dc385e017d2b38120e8ce580" title="CubeApproach::readTopSensors" alt="" coords="278,107,487,133"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_a2e637df1eece269b680fe9313798c241_icgraph.png" border="0" usemap="#class_cube_approach_a2e637df1eece269b680fe9313798c241_icgraph" alt=""/></div>
<map name="class_cube_approach_a2e637df1eece269b680fe9313798c241_icgraph" id="class_cube_approach_a2e637df1eece269b680fe9313798c241_icgraph">
<area shape="rect" id="node3" href="class_cube_approach.html#ac36a5c38b1108d4cd77172062e1795be" title="CubeApproach::doJob" alt="" coords="267,5,416,32"/><area shape="rect" id="node5" href="class_state_machine.html#a32064aba8c9fa4afcb649d01aaf5fd78" title="StateMachine::doJob" alt="" coords="464,5,608,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a7d68e4fab2b3f7590b21aef387855633"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="class_cube_approach.html#a7d68e4fab2b3f7590b21aef387855633">CubeApproach::turn</a> </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>direction</em></td><td>)</td>
          <td><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Creates an extended move command and executes it. </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">direction</td><td>1=turn left, 2=turn right </td></tr>
  </table>
  </dd>
</dl>

<p>Definition at line <a class="el" href="_cube_approach_8cpp_source.html#l00233">233</a> of file <a class="el" href="_cube_approach_8cpp_source.html">CubeApproach.cpp</a>.</p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_a7d68e4fab2b3f7590b21aef387855633_cgraph.png" border="0" usemap="#class_cube_approach_a7d68e4fab2b3f7590b21aef387855633_cgraph" alt=""/></div>
<map name="class_cube_approach_a7d68e4fab2b3f7590b21aef387855633_cgraph" id="class_cube_approach_a7d68e4fab2b3f7590b21aef387855633_cgraph">
<area shape="rect" id="node3" href="class_extended_move.html#a816f77b595c0ca03d44dd21b2d4de5ba" title="ExtendedMove::startCurrentQueue" alt="" coords="192,28,413,54"/><area shape="rect" id="node5" href="class_communication.html#a8679b3cb7ceef5527faa24454ce0f18a" title="Communication::send" alt="" coords="1001,28,1149,54"/><area shape="rect" id="node7" href="class_extended_move.html#adfe6e7de87eab16e9a85ad5434819fee" title="ExtendedMove::executeCommand" alt="" coords="493,28,713,54"/><area shape="rect" id="node17" href="class_extended_move.html#a80ce42b3578e4fa17b6b2e3a05a70054" title="ExtendedMove::getCurrentCommandInQueue" alt="" coords="461,78,744,105"/><area shape="rect" id="node10" href="class_move.html#a9c5dc5c3a98abece0c2f40085c3601be" title="Move::controlMotors" alt="" coords="792,78,931,105"/><area shape="rect" id="node13" href="class_move.html#af6b1197771f0540b0becc4117d8d272f" title="Move::setLeftMotorDirection" alt="" coords="983,78,1166,105"/><area shape="rect" id="node15" href="class_move.html#a06e67dafd581bbd086da404a90c4eeec" title="Move::setRightMotorDirection" alt="" coords="979,129,1171,156"/></map>
</div>
</p>

<p><div class="dynheader">
Here is the caller graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="class_cube_approach_a7d68e4fab2b3f7590b21aef387855633_icgraph.png" border="0" usemap="#class_cube_approach_a7d68e4fab2b3f7590b21aef387855633_icgraph" alt=""/></div>
<map name="class_cube_approach_a7d68e4fab2b3f7590b21aef387855633_icgraph" id="class_cube_approach_a7d68e4fab2b3f7590b21aef387855633_icgraph">
<area shape="rect" id="node3" href="class_cube_approach.html#ac36a5c38b1108d4cd77172062e1795be" title="CubeApproach::doJob" alt="" coords="192,5,341,32"/><area shape="rect" id="node5" href="class_state_machine.html#a32064aba8c9fa4afcb649d01aaf5fd78" title="StateMachine::doJob" alt="" coords="389,5,533,32"/></map>
</div>
</p>

</div>
</div>
<hr/><h2>Member Data Documentation</h2>
<a class="anchor" id="a1b9e5a99d916ad25e8cb522e9786afe7"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="class_communication.html">Communication</a>* <a class="el" href="class_cube_approach.html#a1b9e5a99d916ad25e8cb522e9786afe7">CubeApproach::_com</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>The reference to the serial communication class. </p>

<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00026">26</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>

</div>
</div>
<a class="anchor" id="a69026de7ba3ae39f7298469faf69759e"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="class_configuration.html">Configuration</a>* <a class="el" href="class_cube_approach.html#a69026de7ba3ae39f7298469faf69759e">CubeApproach::_conf</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>The reference to the configuration class. </p>

<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00028">28</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>

</div>
</div>
<a class="anchor" id="a4e47fc77ece35197d5c1e2dda55334be"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="class_extended_move.html">ExtendedMove</a>* <a class="el" href="class_cube_approach.html#a4e47fc77ece35197d5c1e2dda55334be">CubeApproach::_extMove</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>The reference to the extended move class. </p>

<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00029">29</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>

</div>
</div>
<a class="anchor" id="a2d3ac039bdca41b375557b0f0270e20d"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="class_line_follow.html">LineFollow</a> <a class="el" href="class_cube_approach.html#a2d3ac039bdca41b375557b0f0270e20d">CubeApproach::_lineFollow</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p><a class="el" href="class_line_follow.html">LineFollow</a> instance for the cube approach. </p>

<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00031">31</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>

</div>
</div>
<a class="anchor" id="a0e1bfa9a8ab15c7762e4af35b4605003"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int const <a class="el" href="class_cube_approach.html#a0e1bfa9a8ab15c7762e4af35b4605003">CubeApproach::_MAXRECORDABLECUBEDETECTIONS</a> = 20<code> [static, private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Defines, how many cube detections can be recorded. </p>

<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00022">22</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>

</div>
</div>
<a class="anchor" id="a91fd46dd8a9d594c3d6e516406bc4440"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="class_move.html">Move</a>* <a class="el" href="class_cube_approach.html#a91fd46dd8a9d594c3d6e516406bc4440">CubeApproach::_move</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>The reference to the move class to control the motors. </p>

<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00027">27</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>

</div>
</div>
<a class="anchor" id="a3831bd3f8a43dcdb1ca3c1ba185f43c4"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int <a class="el" href="class_cube_approach.html#a3831bd3f8a43dcdb1ca3c1ba185f43c4">CubeApproach::_stopCarExtMoveCommandId</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>The id of the ext move command that is responsible for stopping the car after the cube has been detected the first time. </p>
<p>Per default this value is set to -1. This means, that the command has not yet been executed. The <a class="el" href="class_cube_approach.html#ac36a5c38b1108d4cd77172062e1795be">doJob()</a> method will therefore execute this command. After starting it's execution <a class="el" href="class_cube_approach.html#ac36a5c38b1108d4cd77172062e1795be">doJob()</a> will wait until the execution of this command has finished. Then the second part of the cube approach algorithm (second part: cube approach without following the line) starts. </p>

<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00040">40</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>

</div>
</div>
<a class="anchor" id="aae0fa8f88f1ea1c01e8528d7798a7db2"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">boolean <a class="el" href="class_cube_approach.html#aae0fa8f88f1ea1c01e8528d7798a7db2">CubeApproach::_stopCarNotYetDone</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>True as long as "stop car" has not yet been performed. </p>
<dl class="section see"><dt>See also:</dt><dd><a class="el" href="class_cube_approach.html#a3831bd3f8a43dcdb1ca3c1ba185f43c4" title="The id of the ext move command that is responsible for stopping the car after the cube has been detec...">_stopCarExtMoveCommandId</a> </dd></dl>

<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00041">41</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>

</div>
</div>
<a class="anchor" id="ae99890596905ad65ee8a36a072a151cd"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">unsigned long <a class="el" href="class_cube_approach.html#ae99890596905ad65ee8a36a072a151cd">CubeApproach::_timeLastCubeApproachCheck</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Holds the timestamp of the time when the last cube approach check was done. </p>
<dl class="section see"><dt>See also:</dt><dd><a class="el" href="class_cube_approach.html#ac36a5c38b1108d4cd77172062e1795be">doJob()</a> </dd></dl>

<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00024">24</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>

</div>
</div>
<a class="anchor" id="a6c44784cf83ba56f87895bb5c841e7df"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int <a class="el" href="class_cube_approach.html#a6c44784cf83ba56f87895bb5c841e7df">CubeApproach::amountOfCubeDetections</a></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Counter that is increased each time the cube is detected by either the left or the right sensor. </p>

<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00049">49</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>

</div>
</div>
<a class="anchor" id="aeac3597ee8adcaf33fbf1a523de7c8e9"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="struct_cube_detection.html">CubeDetection</a> <a class="el" href="class_cube_approach.html#aeac3597ee8adcaf33fbf1a523de7c8e9">CubeApproach::cubeDetections</a>[<a class="el" href="class_cube_approach.html#a0e1bfa9a8ab15c7762e4af35b4605003">_MAXRECORDABLECUBEDETECTIONS</a>]</td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_cube_approach_8h_source.html#l00048">48</a> of file <a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a>.</p>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>D:/Workspace/Arduino/prencar/<a class="el" href="_cube_approach_8h_source.html">CubeApproach.h</a></li>
<li>D:/Workspace/Arduino/prencar/<a class="el" href="_cube_approach_8cpp_source.html">CubeApproach.cpp</a></li>
</ul>
</div><!-- contents -->
</div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="class_cube_approach.html">CubeApproach</a>      </li>

    <li class="footer">Generated on Thu Jun 7 2012 20:47:45 for prencar by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.0 </li>
   </ul>
 </div>


</body>
</html>
